package com.zm.demo.core.pattern.abstractfactory;

/**
 * Created by Administrator on 2019/7/29.
 */
public class CarFactoryFactory {

    public static CarFactory getCarfactory(String name){
        switch (name){
            case "HF": return new HFFactory();
            case "QQ": return new QQFactory();
            default:throw new RuntimeException("不支持的车型");
        }
    }
}
